//
//  ClientEmptyView.swift
//  swiftProject
//
//  Created by ZhangSai on 2021/6/10.
//

import UIKit

protocol ClientEmptyDelegate:class {
    func homeViewAcrionDelegate(actonType:HomeViewActonType)
}


class ClientEmptyView: UIView {
    weak var delegate:ClientEmptyDelegate?
    @IBOutlet weak var logisticsTitleLab: UILabel!
    @IBOutlet weak var messageLab: UILabel!
    @IBOutlet weak var bgView: UIView!

    override func awakeFromNib() {
        super.awakeFromNib()
        NotificationCenter.default.addObserver(self, selector: #selector(setUI), name: NSNotification.Name(rawValue: "languageNotification"), object: nil)
        self.setUI()
    }

    @objc func setUI() {
        self.logisticsTitleLab.text = ZslanguageTool.sharedLanguageTool().getIanguageWithKey(key: LanguageHeader.order_logistics_statistics)
        self.messageLab.text = ZslanguageTool.sharedLanguageTool().getIanguageWithKey(key: LanguageHeader.order_senderNotData)
    }
    
    override func touchesBegan(_ touches: Set<UITouch>, with event: UIEvent?) {
        super.touchesBegan(touches, with: event)
        self.delegate?.homeViewAcrionDelegate(actonType: HomeViewActonType.Home_EndEditingType)
    }
}
